package com.zzdx.deployment.system.service.impl;

import java.util.List;

import com.zzdx.deployment.system.domain.CompanyAndPc;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.zzdx.deployment.system.mapper.PcMapper;
import com.zzdx.deployment.system.domain.Pc;
import com.zzdx.deployment.system.service.IPcService;
import com.zzdx.deployment.common.support.Convert;

/**
 * 批次 服务层实现
 * 
 * @author zzdx
 * @date 2020-03-08
 */
@Service
public class PcServiceImpl implements IPcService 
{
	@Autowired
	private PcMapper pcMapper;

	/**
     * 查询批次信息
     * 
     * @param pcId 批次ID
     * @return 批次信息
     */
    @Override
	public Pc selectPcById(Integer pcId)
	{
	    return pcMapper.selectPcById(pcId);
	}
	
	/**
     * 查询批次列表
     * 
     * @param pc 批次信息
     * @return 批次集合
     */
	@Override
	public List<Pc> selectPcList(Pc pc)
	{
	    return pcMapper.selectPcList(pc);
	}
	
    /**
     * 新增批次
     * 
     * @param pc 批次信息
     * @return 结果
     */
	@Override
	public int insertPc(Pc pc)
	{
	    return pcMapper.insertPc(pc);
	}
	
	/**
     * 修改批次
     * 
     * @param pc 批次信息
     * @return 结果
     */
	@Override
	public int updatePc(Pc pc)
	{
	    return pcMapper.updatePc(pc);
	}

	/**
     * 删除批次对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
	@Override
	public int deletePcByIds(String ids)
	{
		return pcMapper.deletePcByIds(Convert.toStrArray(ids));
	}

	@Override
	public int applyFirst(Integer pcId,String applyMsg) {
		return pcMapper.applyFirst(pcId,applyMsg);
	}

	@Override
	public int applySecond(Integer pcId,String applyMsg) {
		return pcMapper.applySecond(pcId,applyMsg);
	}

}
